NAME: Upload Avatar <br />VERSION: 1.0.1 <br />DESCRIPTION: Allows an administrator to upload a user's avatar. <br />WORKING UNDER: UBB.threads 6.2.2-6.3b1 <br />PREREQUISITES: PHP >= 4.0.5 <br />AUTHORS: Dave Lerner (Dave_L) <br />CREDITS: none <br />DEMO: none <br />FILES ALTERED: admin/menu.php <br />DATABASE ALTERED: yes (updates Users.U_Picture, Users.U_PicWidth and Users.U_PicHeight) <br />NEW FILES: admin/upload_avatar.php <br /> <br />HISTORY: <br /> 2003-03-01 Dave_L - 1.0.0 Original release <br /> 2003-04-21 Dave_L - 1.0.1 Updated instructions for UBB.threads 6.3b1 <br /> <br />******** <br />ABSTRACT <br />******** <br /> <br />This addon script allows an administrator to upload an avatar for a user, regardless of whether users are permitted to upload their own avatars. The database is updated appropriately. <br /> <br />The avatar directory path, URL and the maximum avatar file size are obtained from the config settings $config['avatars'], $config['avatarurl'] and $config['avatarsize']. <br /> <br />The maximum avatar dimensions are obtained from the theme settings $theme['PictureWidth'] and $theme['PictureHeight']. <br /> <br />The permissible avatar file types (.gif, .jpg and .png) are hardcoded here. <br /> <br />The PHP function getimagesize is used for checking the image dimensions and image type. <br /> <br />------------ <br />P.S. The instructions show how to add this function to the admin menu, but you can also run this as a standalone script, if you prefer not to modify admin/menu.php.
Attachments
76561-upload_avatar_1-0-1.zip (216 downloads)
_________________________
UBB.threads beta tester / threadsdev.com moderator
Software consulting services including UBB.threads problem resolution / installs / upgrades / customization.